package com.qa.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.qa.IDao.SortMapper;
import com.qa.pojo.Sort;
import com.qa.pojo.Sort_Func;
import com.qa.pojo.TestCase;
import com.qa.service.ITestCaseService;

@Service("testCaseService")
public class ITestCaseImpl implements ITestCaseService {
	@Resource
	private SortMapper sortDao;

	@Override
	public List<Sort> getSorts() {
		// TODO Auto-generated method stub
		return this.sortDao.getAllSorts();
	}

	@Override
	public List<Sort_Func> getSort_func() {
		// TODO Auto-generated method stub
		return this.sortDao.getSort_func();
	}

	@Override
	public List<TestCase> selectCase(int sort, int func,
			List<Integer> examineGroup, int caseAscr, String selectFunction,
			String selectKeyword, int usersid) {

		return this.sortDao.selectCase(sort, func, examineGroup, caseAscr,
				selectFunction, selectKeyword, usersid);
	}

	@Override
	public int insertTestCase(int sortAdd, int funcAdd, String funchildname,
			String step, String expectresult, String remark, int usersid) {

		return this.sortDao.insertTestCase(sortAdd, funcAdd, funchildname,
				step, expectresult, remark, usersid);
	}

	@Override
	public int editTestCase(int editCaseId, int sortEdit, int funcEdit,
			String funchildnameEdit, String stepEdit, String expectresultEdit,
			String remarkEdit) {
		// TODO Auto-generated method stub
		return this.sortDao.editTestCase(editCaseId, sortEdit, funcEdit,
				funchildnameEdit, stepEdit, expectresultEdit, remarkEdit);
	}

	@Override
	public int deleteTestCase(List<Integer> signGroupList) {
		// TODO Auto-generated method stub
		return this.sortDao.deleteTestCase(signGroupList);
	}

	@Override
	public int examineTestCase(int caseId) {
		// TODO Auto-generated method stub
		return this.sortDao.examineTestCase(caseId);
	}

}
